package com.hjf.booking.constants;

import java.math.BigDecimal;
import java.util.HashMap;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

public class ConstantsRef {

    public static final byte PIC_BODY = 11;
    public static final byte PIC_PERSON = 12;
    public static final byte VIDEO_BODY = 21;
    public static final byte VIDEO_PERSON = 22;


    /**
     * 淘宝订单状态
     */
    public static final class TaobaoOrderStatus {
        public static final String TRADE_NO_CREATE_PAY = "TRADE_NO_CREATE_PAY";//(没有创建支付宝交易)
        public static final String WAIT_BUYER_PAY = "WAIT_BUYER_PAY";//(等待买家付款)
        public static final String SELLER_CONSIGNED_PART = "SELLER_CONSIGNED_PART";//(卖家部分发货)
        public static final String WAIT_SELLER_SEND_GOODS = "WAIT_SELLER_SEND_GOODS";//(等待卖家发货,即:买家已付款)
        public static final String WAIT_BUYER_CONFIRM_GOODS = "WAIT_BUYER_CONFIRM_GOODS";//(等待买家确认收货,即:卖家已发货)
        public static final String TRADE_BUYER_SIGNED = "TRADE_BUYER_SIGNED";//(买家已签收,货到付款专用)
        public static final String TRADE_FINISHED = "TRADE_FINISHED";//(交易成功)
        public static final String TRADE_CLOSED = "TRADE_CLOSED";//(付款以后用户退款成功，交易自动关闭)
        public static final String TRADE_CLOSED_BY_TAOBAO = "TRADE_CLOSED_BY_TAOBAO";//(付款以前，卖家或买家主动关闭交易)
        public static final String PAY_PENDING = "PAY_PENDING";//(国际信用卡支付付款确认中)
        public static final String WAIT_PRE_AUTH_CONFIRM = "WAIT_PRE_AUTH_CONFIRM";//(0元购合约中)
        public static final String PAID_FORBID_CONSIGN = "PAID_FORBID_CONSIGN";//(拼团中订单或者发货强管控的订单，已付款但禁止发货)
    }

    /**
     * 淘宝退款状态
     */
    public static final class TaobaoRefundStatus {
        public static final String WAIT_SELLER_AGREE = "WAIT_SELLER_AGREE";//(买家已经申请退款，等待卖家同意)
        public static final String WAIT_BUYER_RETURN_GOODS = "WAIT_BUYER_RETURN_GOODS";//(卖家已经同意退款，等待买家退货)
        public static final String WAIT_SELLER_CONFIRM_GOODS = "WAIT_SELLER_CONFIRM_GOODS";//(买家已经退货，等待卖家确认收货)
        public static final String SELLER_REFUSE_BUYER = "SELLER_REFUSE_BUYER";//(卖家拒绝退款)
        public static final String CLOSED = "CLOSED";//(退款关闭)
        public static final String SUCCESS = "SUCCESS";//(退款成功)
    }







    public static class ReturnMoneyStatus {
        public static final byte WAIT_DEAL = 0;//待处理
        public static final byte TRANSFERED = 1;//审核并转账
        public static final byte REFUSED = 2;//申请被拒绝
        public static final byte API_ERROR = 3;//微信转账接口问题，转账失败
        public static final byte NO_NEED_RETURN_CAPITAL = 4;//无需返本金（只返佣金模式下）


        public static final byte TERMINATION = -1;//终止

    }

    public static class ReturnCommissionStatus {
        public static final byte WAIT_DEAL = 0;//待处理
        public static final byte TRANSFERED = 1;//审核并转账
        public static final byte REFUSED = 2;//申请被拒绝
        public static final byte API_ERROR = 3;//微信转账接口问题，转账失败
    }


    public static Map<Byte, String> returnMoneyStatusMap = new HashMap<>();

    static {
        returnMoneyStatusMap.put(ReturnMoneyStatus.WAIT_DEAL, "待处理");
        returnMoneyStatusMap.put(ReturnMoneyStatus.TRANSFERED, "已返本金");
        returnMoneyStatusMap.put(ReturnMoneyStatus.REFUSED, "拒返本金");
        returnMoneyStatusMap.put(ReturnMoneyStatus.API_ERROR, "操作失败，可重新操作");
        returnMoneyStatusMap.put(ReturnMoneyStatus.NO_NEED_RETURN_CAPITAL, "无需返本金");
    }

    public static Map<Byte, String> returnCommissionStatusMap = new HashMap<>();

    static {
        returnCommissionStatusMap.put(ReturnCommissionStatus.WAIT_DEAL, "待处理");
        returnCommissionStatusMap.put(ReturnCommissionStatus.TRANSFERED, "已返佣");
        returnCommissionStatusMap.put(ReturnCommissionStatus.REFUSED, "已拒绝返佣");
        returnCommissionStatusMap.put(ReturnCommissionStatus.API_ERROR, "操作失败，可重新操作");
    }


    public static final Map<String, String> taobaoOrderStatusMap = new HashMap<>();

    static {
        taobaoOrderStatusMap.put(TaobaoOrderStatus.WAIT_BUYER_PAY, "等待买家付款");
        taobaoOrderStatusMap.put(TaobaoOrderStatus.SELLER_CONSIGNED_PART, "卖家部分发货");
        taobaoOrderStatusMap.put(TaobaoOrderStatus.WAIT_SELLER_SEND_GOODS, "等待卖家发货");
        taobaoOrderStatusMap.put(TaobaoOrderStatus.WAIT_BUYER_CONFIRM_GOODS, "等待买家确认收货");
        taobaoOrderStatusMap.put(TaobaoOrderStatus.TRADE_FINISHED, "交易成功");
        taobaoOrderStatusMap.put(TaobaoOrderStatus.TRADE_CLOSED, "交易关闭");
        taobaoOrderStatusMap.put(TaobaoOrderStatus.TRADE_CLOSED_BY_TAOBAO, "付款前主动关闭");
    }


    public static final Map<String, String> TaobaoRefundStatusMap = new HashMap<>();

    static {
        TaobaoRefundStatusMap.put(TaobaoRefundStatus.WAIT_SELLER_AGREE, "买家已经申请退款，等待卖家同意");
        TaobaoRefundStatusMap.put(TaobaoRefundStatus.WAIT_BUYER_RETURN_GOODS, "卖家已经同意退款，等待买家退货");
        TaobaoRefundStatusMap.put(TaobaoRefundStatus.WAIT_SELLER_CONFIRM_GOODS, "买家已经退货，等待卖家确认收货");
        TaobaoRefundStatusMap.put(TaobaoRefundStatus.SELLER_REFUSE_BUYER, "卖家拒绝退款");
        TaobaoRefundStatusMap.put(TaobaoRefundStatus.CLOSED, "退款关闭");
        TaobaoRefundStatusMap.put(TaobaoRefundStatus.SUCCESS, "退款成功");
    }


    /**
     * 商家的操作模式：
     * 1.本金佣金一起返  2.本金立返，佣金货返
     * 3.只返佣金(本金通过其他平台、工具已返款)
     * 4.佣金立返，本金货返
     */
    public static class RETURN_MONEY_MODE {
        public static final byte CAPITAL_WITH_COMMISSION_ALL = (byte) 1;
        public static final byte CAPITAL_NOW_AND_COMMISSION_RECEIVE = (byte) 2;
        public static final byte COMMISSION_ONLY = (byte) 3;
        public static final byte COMMISSION_NOW_AND_CAPITAL_RECEIVE = (byte) 4;
    }


    public static class MERCHANT_ACCOUNT_TYPE {
        public static final byte MASTER = (byte) 1;
        public static final byte SLAVE = (byte) 2;
    }

    /**
     * 工具模式：1.自有商户号返款  2.中心化红包代返
     */
    public static class TOOL_MODE {
        public static final byte HAS_WECHAT_MCHID = (byte) 1; //自有商户号返款
        public static final byte CENTRAL_REDPACKET = (byte) 2;//中心化红包代返
    }

    /**
     * 平台红包充值的手续费比例
     * 由之前充值时统一扣除，调整为：每笔交易发生时进行扣除
     */
    public static final BigDecimal FEE_PERCENT = new BigDecimal("0.00");

    /**
     * 红包任务状态： 1：正常 4：终止/暂停 -1：删除
     */
    public static class TASK_STATUS {
        public static final byte NORMAL = (byte) 1;
        public static final byte STOP = (byte) 4;
        public static final byte DELETE = (byte) -1;

        public static final byte FINISHED = (byte) 9;
    }

    /**
     * 红包任务类型：1:普通返款红包   2:好评返现红包  3，4... 营销红包等营销场景
     */
    public static class TASK_TYPE {
        public static final byte NORMAL = (byte) 1; //普通中心化返款红包
        public static final byte COMMENT_AWARD = (byte) 2;//好评返现红包
        public static final byte BATCH_AWARD = (byte) 3;//批量红包
        public static final byte AD_AWARD = (byte) 4;//广告红包

    }

    public static Map<Byte, String> taskTypeMap = new HashMap<>();

    static {
        taskTypeMap.put(TASK_TYPE.NORMAL, "返款红包");
        taskTypeMap.put(TASK_TYPE.COMMENT_AWARD, "好评返现红包");
        taskTypeMap.put(TASK_TYPE.BATCH_AWARD, "批量红包");
        taskTypeMap.put(TASK_TYPE.AD_AWARD, "广告红包");
    }

    /**
     * 淘客检测：1毛/1次 1点相当于1分
     */
    public static final BigDecimal CHECK_TAOKE_AMOUNT_PER_TIME = new BigDecimal("10");


    //主账号最多创建3个
    public static final int MAX_CREATE_SUB_ACCOUNT_NUM = 3;


    public static final int AUTH_SHOP_VALID_DAYS = 15;


    public static Map<Byte, String> auditStatusMap = new HashMap<>();

    //平台每笔订单收入（服务费）
    public static final BigDecimal PLATFORM_EACH_ORDER_INCOME = new BigDecimal("8");

    //平台每笔打标订单收入（服务费）
    public static final BigDecimal PLATFORM_EACH_LABEL_ORDER_INCOME = new BigDecimal("1");

    static {
        auditStatusMap.put(new Byte("0"), "正在审核");
        auditStatusMap.put(new Byte("1"), "通过审核");
        auditStatusMap.put(new Byte("2"), "审核未通过");
    }

    //代理的每笔抽佣
    public static final BigDecimal AGENT_GET_TRANS_COMMISSION = BigDecimal.ONE;

    //平台的每笔服务费
    public static final BigDecimal PLATFORM_GET_TRANS_SERVICE_FEE = new BigDecimal("0.5");

    //充值审核状态
    public static final Map<Byte, String> rechargeAuditStatusMap = new HashMap<>();

    static {
        rechargeAuditStatusMap.put((byte) 10, "待审核");
        rechargeAuditStatusMap.put((byte) 14, "审核不通过");
        rechargeAuditStatusMap.put((byte) 20, "审核通过");
    }


    //店铺授权有效天数
    public static final int SHOP_TOKEN_EFFECTIVE_DAY = 20;
    /*****************活动发布*********************/
    public static final Map<Byte, String> activityStatusMap = new HashMap<>();

    public static final byte ACTIVITY_TYPE_OF_EXCHANGE = 1;//兑换活动
    public static final byte ACTIVITY_TYPE_OF_LABEL = 2;//打标活动
    public static final byte ACTIVITY_TYPE_OF_REBATE_WITH_EXCHANGE = 3;//"返利特卖"


    /**
     * 返款模式
     */
    public static final class REFUND_MODE {
        public static final byte PLATFORM = (byte) 0; //平台返款模式
        public static final byte MERCHANT = (byte) 1; //商家返款模式


        public static final byte MERCHANT_REDUCE_SERVICE_FEE = 0;//商家返款模式降低的服务费用
    }


    /**
     * 活动方案
     * 活动类型的下级；但也代表一种活动类型；如：打标活动下存在【仅浏览竞品】,【浏览竞品和自己商品】两种方案
     * 21：可以代表【打标活动】类型的【仅浏览竞品】方案，也可以认为是【打标活动仅浏览竞品】的活动类型
     * 22：可以代表【打标活动】类型的【浏览竞品和自己商品】方案，也可以认为是【打标活动浏览竞品和自己商品】的活动类型
     */
    public static final byte ACTIVITY_SCHEME_OF_LABEL_RIVAL = 21;//打标活动-仅浏览竞品
    public static final byte ACTIVITY_SCHEME_OF_LABEL_BOTH = 22;//打标活动-浏览竞品和自己商品

    public static final byte LABEL_DAY_TIMES_LIMIT = 1;//同一商品同一买家一天最多打标1次
    public static final byte LABEL_DAY_TIMES_FOR_DIFFERENT_LIMIT_FOR_LIKE = 10;//针对不同喜欢商品，同一买家一天最多打标3次
    public static final byte LABEL_DAY_TIMES_FOR_DIFFERENT_LIMIT_FOR_SUPERLIKE = 4;//针对不同超级喜欢商品，同一买家一天最多打标1次
    public static final byte LABEL_DAY_TIMES_FOR_DIFFERENT_LIMIT = LABEL_DAY_TIMES_FOR_DIFFERENT_LIMIT_FOR_LIKE + LABEL_DAY_TIMES_FOR_DIFFERENT_LIMIT_FOR_SUPERLIKE;//针对不同商品，同一买家一天最多打标3次

    public static final byte LABEL_WEEK_TIMES_LIMIT = 4;//同一商品同一买家一周最多打标3次
    public static final byte LABEL_WAIT_VERIFY_LIST_LIMIT = 4;//用户打标待核对列表最多3个


    /**
     * 活动订单类型（针对expert_exchange_order的order_type）
     */
    public static final byte ORDER_TYPE_OF_EXCHANGE = 1;//黑钻兑换
    public static final byte ORDER_TYPE_OF_REBATE = 2;//返利特卖


    //活动发布状态
    public static final byte ACTIVITY_STATUS_OF_DRAFT = 0;//草稿状态
    public static final byte ACTIVITY_STATUS_OF_PUBLISHED = 1;//审核通过并发布(【返利特卖类型需审核】)
    public static final byte ACTIVITY_STATUS_OF_NOT_PASSED = 2;//审核不通过（返利特卖类型需审核】）
    public static final byte ACTIVITY_STATUS_OF_WAIT_AUDIT = 3;//待审核状态
    public static final byte ACTIVITY_STATUS_OF_STOPPED = 4;//已终止
    public static final byte ACTIVITY_STATUS_OF_FINISHED = 9;//已完成（完成结算）

    static {
        activityStatusMap.put(ACTIVITY_STATUS_OF_DRAFT, "草稿");
        activityStatusMap.put(ACTIVITY_STATUS_OF_PUBLISHED, "已发布");
        activityStatusMap.put(ACTIVITY_STATUS_OF_NOT_PASSED, "审核未通过");
        activityStatusMap.put(ACTIVITY_STATUS_OF_WAIT_AUDIT, "待审核");
        activityStatusMap.put(ACTIVITY_STATUS_OF_STOPPED, "活动已终止");
        activityStatusMap.put(ACTIVITY_STATUS_OF_FINISHED, "活动已完成");
    }

    //活动进行状态
    public static final String ACTIVITY_TYPE_OF_INDEX = "index";//C端首页：展示进行中、已结束
    public static final String ACTIVITY_TYPE_OF_SOON = "soon";//活动即将开始
    public static final String ACTIVITY_TYPE_OF_PROCESSING = "processing";//活动进行中
    public static final String ACTIVITY_TYPE_OF_FINISHED = "finished";//活动已结束 -> 改为活动已抢光

    //绑定状态
    public static final byte BIND_CHOOSE_YES = 1;//需绑定
    public static final byte BIND_CHOOSE_NO = 0;//不绑定

    //已参与兑换过，该商品所属店铺的活动，30天内不能再次参与
    public static final byte NOT_JOINED_DAY_LIMIT = -30;

    public static final byte YES = 1;
    public static final byte NO = 0;

    public static final byte NORMAL = 0;//记录正常
    public static final byte DELETE = -1;//记录逻辑删除标记位


    public static final int DIRECTIONAL_EXCHANGE_LEAST_TARGET_NUM = 80;//定向回购的最小目标人数
    public static final int DIRECTIONAL_EXCHANGE_FOR_COMPETE_LEAST_TARGET_NUM = 40;//卡竞品标签回购的最小目标人数

//    public static final int DIRECTIONAL_EXCHANGE_LEAST_TARGET_NUM = 0;//定向回购的最小目标人数
//    public static final int DIRECTIONAL_EXCHANGE_FOR_COMPETE_LEAST_TARGET_NUM = 0;//卡竞品标签回购的最小目标人数

    public static final BigDecimal AWARD_FOR_DIRECTIONAL = BigDecimal.ONE; //额外奖励1元给回购活动
    public static final BigDecimal AWARD_FOR_AWARD_FOR_NEW_USER = new BigDecimal("5"); //新人首单额外奖励5元

    //当天消耗完所有兑换次数，额外奖励5元
    public static final BigDecimal AWARD_FOR_AWARD_FOR_DAY_FINISH_TASK = new BigDecimal("5");

    /*****************商品兑换*********************/
    //买家当天可兑换付款活动商品的最大次数
    public static final byte EXCHANGED_MAX_TIMES_FOR_PROMOTION = 4;
    //买家当天可兑换清单商品的最大次数
    public static final byte EXCHANGED_MAX_TIMES_FOR_LIKE = 1;
    //买家当天可兑换商品的最大次数
    public static final byte EXCHANGED_MAX_TIMES = EXCHANGED_MAX_TIMES_FOR_PROMOTION + EXCHANGED_MAX_TIMES_FOR_LIKE;
    //用户本周可免费兑换商品的最大次数
    public static final byte FREE_EXCHANGED_MAX_TIMES_FOR_WEEK = 3;
    //超过本周抢购次数限制需要黑钻比例
    public static final BigDecimal OVER_WEEK_FREE_LIMIT_NEED_BLACKDIAMOND_RATE = new BigDecimal("0.5");
    //商品兑换失败重试次数
    public static final byte EXCHANGE_FAILED_TRY_TIMES = 3;
    //单次兑换答题的最大题数
    public static final byte EXCHANGE_QA_MAX_NUM = 2;
    //兑换后答题时间设置
    public static final byte EXCHANGE_QA_MAX_TIME_MINUTES = 30;//答题时间为最多30分钟
    //兑换提交阶段时间设置
    public static final byte EXCHANGE_ORDER_SUBMIT_MAX_TIME_MINUTES = 30;//兑换提交阶段最多30分钟

    /*****************提交淘宝测评*********************/
    public static final byte SUBMIT_TAOBAO_EVALUATE_LIMIT_DAYS = 7;//买家收到商家邀请后，提交淘宝测评的最大超时时间，超时则视为放弃

    public static final byte SUBMIT_TAOBAO_EVALUATE_SETTLE_DAYS = 1;//买家提交淘宝测评后，商家结算时间

    public static final BigDecimal SUBMIT_TAOBAO_EVALUATE_FROZEN_DIAMONDS_HIGH_QUALITY = new BigDecimal("10.00");//商家邀请买家评测冻结服务费

    public static final BigDecimal SUBMIT_TAOBAO_EVALUATE_FROZEN_DIAMONDS_ORDINARY = new BigDecimal("5.00");//商家邀请买家评测冻结服务费

    public static Map<Byte, String> enterShopMap = new HashMap<>();


    static {
        enterShopMap.put((byte) 1, "关键字");
        enterShopMap.put((byte) 2, "淘口令");
        enterShopMap.put((byte) 3, "二维码");
        enterShopMap.put((byte) 0, "自定义");
    }

    /**
     * 状态统一可以以模块化、枚举型管理
     * 兑换状态：兑换状态：0.待兑换（点了我要兑换，进入答题阶段）；
     * <p>
     * 1：待提交（填写提交信息）；
     * 2.答案错误且达限定核对次数，失去兑换资格；
     * 3：已提交，待签收；
     * 4：已签收；
     * 5：售后中；
     * -1：主动放弃兑换；
     * -2：由于答题超时失去兑换资格；
     * -3：由于提交超时失去兑换资格；
     * 9：已完成
     * </p>
     */
    public static enum ExchangeStatusEnum {
        EXCHANGE_ORDER_INIT((byte) 0),//待兑换
        EXCHANGE_ORDER_WAIT_SUBMIT((byte) 1),//订单待提交
        EXCHANGE_ORDER_SUBMITED_AND_WAIT_RECEIVE((byte) 3),//已提交，待签收
        EXCHANGE_ORDER_RECEIVED((byte) 4),//已签收
        EXCHANGE_ORDER_SALING((byte) 5),//售后中
        EXCHANGE_ORDER_GIVEUP((byte) -1),//主动放弃兑换
        EXCHANGE_ORDER_LOSS_FOR_QA_TIMEOUT((byte) -2),//由于抢购超时失去兑换资格
        EXCHANGE_ORDER_LOSS_FOR_SUMIT_TIMEOUT((byte) -3),//由于提交超时失去兑换资格
        EXCHANGE_ORDER_CLOSED((byte) 6),//已关闭
        EXCHANGE_ORDER_FINISHED((byte) 9),//已完成

        EXCHANGE_ORDER_FINISHED_WAIT_TRANSFER((byte) 91),//待返款
        EXCHANGE_ORDER_FINISHED_AND_TRANSFERED((byte) 99);//已返款

        private byte value;

        ExchangeStatusEnum(byte value) {
            this.value = value;

        }

        public final byte getValue() {
            return value;
        }

        public void setValue(byte value) {
            this.value = value;
        }
    }

    /**
     * 不太优雅的做法：同时保留了常量定义和上面的枚举常量定义
     * 初衷是打算统一使用枚举进行管理，但对于mapper中使用枚举常量要特别处理，
     * 后续以类似"${@com.xiaowo.backend.constants.ConstantsRef.ExchangeStatusEnum@INCOME.getValue()}"
     * 的方式处理替换
     */
    public static final byte EXCHANGE_ORDER_INIT = 0;//待兑换
    public static final byte EXCHANGE_ORDER_WAIT_SUBMIT = 1;//订单待提交
    public static final byte EXCHANGE_ORDER_SUBMITED_AND_WAIT_RECEIVE = 3;//已提交，待签收
    public static final byte EXCHANGE_ORDER_RECEIVED = 4;//已签收
    public static final byte EXCHANGE_ORDER_SALING = 5;//售后中
    public static final byte EXCHANGE_ORDER_GIVEUP = -1;//主动放弃兑换
    public static final byte EXCHANGE_ORDER_LOSS_FOR_INIT_TIMEOUT = -2;//由于兑换超时失去兑换资格
    public static final byte EXCHANGE_ORDER_LOSS_FOR_SUBMIT_TIMEOUT = -3;//由于提交超时失去兑换资格
    public static final byte EXCHANGE_ORDER_CLOSED = 6;//已关闭
    public static final byte EXCHANGE_ORDER_FINISHED = 9;//已完成

    public static final byte EXCHANGE_ORDER_FINISHED_WAIT_TRANSFER = 91;//待返款
    public static final byte EXCHANGE_ORDER_FINISHED_AND_TRANSFERED = 99;//已返款

    public static Map<Byte, String> exchangeStatusMap = new HashMap<>();

    static {
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_INIT, "待核对");
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_WAIT_SUBMIT, "待提交");
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_SUBMITED_AND_WAIT_RECEIVE, "待签收");
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_RECEIVED, "已签收");
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_SALING, "售后中");
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_FINISHED, "已完成");
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_GIVEUP, "已放弃");
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_LOSS_FOR_INIT_TIMEOUT, "已放弃");
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_LOSS_FOR_SUBMIT_TIMEOUT, "已放弃");
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_CLOSED, "已关闭");

        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_FINISHED_WAIT_TRANSFER, "待返款");
        exchangeStatusMap.put(ConstantsRef.EXCHANGE_ORDER_FINISHED_AND_TRANSFERED, "已返款");
    }


    public static Map<Long, Boolean> addingToNewUserActivityTaskProcMap = new ConcurrentHashMap<>();


    public static enum EvaluateStatusEnum {
        EVALUATE_WAIT_SUBMIT((byte) 1),//待提交
        EVALUATE_SUBMITED_WAIT_MERCHANT_CONFIRM((byte) 2),//已提交待确认
        EVALUATE_FINISHED((byte) 9),//已完成
        EVALUATE_GIVEUP((byte) -1),//已放弃

        EVALUATE_TO_BE_RELEASED((byte) 1),
        EVALUATE_TO_BE_REVIEW((byte) 2),
        EVALUATE_TO_BE_INVITATION((byte) 3),
        EVALUATE_TO_BE_SUBMIT((byte) 4),
        EVALUATE_TO_BE_ENTER((byte) 5),
        EVALUATE_AFTER_SALE((byte) 6),
        EVALUATE_COMPLETE((byte) 7),
        EVALUATE_TO_BE_GIVEUP((byte) 8),
        EVALUATE_CLOSE((byte) 9);


        private byte value;

        EvaluateStatusEnum(byte value) {
            this.value = value;

        }

        public final byte getValue() {
            return value;
        }

        public void setValue(byte value) {
            this.value = value;
        }
    }

    //图文测评新的Tab页
    public static final byte EVALUATE_TO_BE_RELEASED = 1;//待发布
    public static final byte EVALUATE_TO_BE_REVIEW = 2;//待评审
    public static final byte EVALUATE_TO_BE_INVITATION = 3;//待邀请
    public static final byte EVALUATE_TO_BE_SUBMIT = 4;//待提交
    public static final byte EVALUATE_TO_BE_ENTER = 5;//待确认
    public static final byte EVALUATE_AFTER_SALE = 6;//售后中
    public static final byte EVALUATE_COMPLETE = 7;//已完成
    public static final byte EVALUATE_TO_BE_GIVEUP = 8;//已放弃
    public static final byte EVALUATE_CLOSE = 9;//已关闭

    public static final byte EVALUATE_WAIT_SUBMIT = 1;//待提交
    public static final byte EVALUATE_SUBMITED_WAIT_MERCHANT_CONFIRM = 2;//已提交待确认
    public static final byte EVALUATE_FINISHED = 9;//已完成
    public static final byte EVALUATE_GIVEUP = -1;//已放弃


    public static Map<Byte, String> evaluateStatusMap = new HashMap<>();

    static {
        evaluateStatusMap.put(ConstantsRef.EVALUATE_WAIT_SUBMIT, "待提交");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_SUBMITED_WAIT_MERCHANT_CONFIRM, "待确认");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_FINISHED, "已完成");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_GIVEUP, "已放弃");

        evaluateStatusMap.put(ConstantsRef.EVALUATE_TO_BE_RELEASED, "待发布");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_TO_BE_REVIEW, "待评审");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_TO_BE_INVITATION, "待邀请");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_TO_BE_SUBMIT, "待提交");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_TO_BE_ENTER, "待确认");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_AFTER_SALE, "售后中");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_COMPLETE, "已完成");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_TO_BE_GIVEUP, "已放弃");
        evaluateStatusMap.put(ConstantsRef.EVALUATE_CLOSE, "已关闭");

    }


    /**
     * 商家端图文测评广场tab列
     */
    public static enum EvaluateBusinessStatusEnum {
        EVALUATE_BUSINESS_INVITATION((byte) 1),
        EVALUATE_BUSINESS_INVITED((byte) 2),
        EVALUATE_BUSINESS_ENTER((byte) 3),
        EVALUATE_BUSINESS_COMPLETE((byte) 4),
        EVALUATE_BUSINESS_AFTER_SALE((byte) 5),
        EVALUATE_BUSINESS_GIVEUP((byte) 6),
        EVALUATE_BUSINESS_CLOSE((byte) 7);
        private byte value;

        EvaluateBusinessStatusEnum(byte value) {
            this.value = value;
        }

        public final byte getValue() {
            return value;
        }

        public void setValue(byte value) {
            this.value = value;
        }
    }

    public static final byte EVALUATE_BUSINESS_INVITATION = 1;//待邀请
    public static final byte EVALUATE_BUSINESS_INVITED = 2;//已邀请
    public static final byte EVALUATE_BUSINESS_ENTER = 3;//待确认
    public static final byte EVALUATE_BUSINESS_COMPLETE = 4;//已完成
    public static final byte EVALUATE_BUSINESS_AFTER_SALE = 5;//售后中
    public static final byte EVALUATE_BUSINESS_GIVEUP = 6;//已放弃
    public static final byte EVALUATE_BUSINESS_CLOSE = 7;//已关闭
    public static Map<Byte, String> evaluateBusinessStatusMap = new HashMap<>();

    static {
        evaluateBusinessStatusMap.put(ConstantsRef.EVALUATE_BUSINESS_INVITATION, "待邀请");
        evaluateBusinessStatusMap.put(ConstantsRef.EVALUATE_BUSINESS_INVITED, "已邀请");
        evaluateBusinessStatusMap.put(ConstantsRef.EVALUATE_BUSINESS_ENTER, "待确认");
        evaluateBusinessStatusMap.put(ConstantsRef.EVALUATE_BUSINESS_COMPLETE, "已完成");
        evaluateBusinessStatusMap.put(ConstantsRef.EVALUATE_BUSINESS_AFTER_SALE, "售后中");
        evaluateBusinessStatusMap.put(ConstantsRef.EVALUATE_BUSINESS_GIVEUP, "已放弃");
        evaluateBusinessStatusMap.put(ConstantsRef.EVALUATE_BUSINESS_CLOSE, "已关闭");
    }


//    public static final byte EVALUATE_STATUS_SUBMIT = 1;//待发布
//    public static final byte EVALUATE_STATUS_SUBMIT = 2;//带审评
//    public static final byte EVALUATE_STATUS_SUBMIT = 3;//待邀请
//    public static final byte EVALUATE_STATUS_SUBMIT = 4;//待提交
//    public static final byte EVALUATE_STATUS_SUBMIT = 5;//待发布
//    public static final byte EVALUATE_STATUS_SUBMIT = 6;//待发布
//    public static final byte EVALUATE_STATUS_SUBMIT = 7;//待发布
//    public static final byte EVALUATE_STATUS_SUBMIT = 8;//待发布


    public static Map<Byte, String> exchangeStatusToolTipMap = new HashMap<>();

    static {
        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_INIT, "等待买家核对商品");
//        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_WAIT_SUBMIT, "等待买家提交订单号");
//        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_SUBMITED_AND_WAIT_RECEIVE,
//                "等待买家确认签收");
//        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_RECEIVED, "买家已确认签收，活动将在48小时内完成");

        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_WAIT_SUBMIT, "等待订单完成");
        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_SALING, "售后处理中");
        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_FINISHED, "活动订单已确认完成");
        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_GIVEUP, "用户已主动放弃兑换");
        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_LOSS_FOR_INIT_TIMEOUT, "用户核对淘口令阶段超时");
        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_LOSS_FOR_SUBMIT_TIMEOUT, "用户提交订单号超时");
        exchangeStatusToolTipMap.put(ConstantsRef.EXCHANGE_ORDER_CLOSED, "小二已对活动进行判定，关闭订单");
    }


    public static enum LabelStatusEnum {
        LABEL_ORDER_INIT((byte) 0),//待兑换
        LABEL_ORDER_WAIT_MERCHANT_CONFIRM((byte) 1),//提交打标活动,等待商家确认
        LABEL_ORDER_FINISHED((byte) 9),//已完成
        LABEL_ORDER_SALING((byte) 5),//售后中
        LABEL_ORDER_GIVEUP((byte) -1),//主动放弃兑换
        LABEL_ORDER_LOSS_FOR_INIT_TIMEOUT((byte) -2),//由于超时失去兑换资格
        LABEL_ORDER_CLOSED((byte) 6);//已关闭

        private byte value;

        LabelStatusEnum(byte value) {
            this.value = value;

        }

        public final byte getValue() {
            return value;
        }

        public void setValue(byte value) {
            this.value = value;
        }
    }

    /**
     * 打标活动状态
     */
    public static final byte LABEL_ORDER_INIT = 0;//打标活动，加入清单
    public static final byte LABEL_ORDER_WAIT_MERCHANT_CONFIRM = 1;//提交打标活动,等待商家确认
    public static final byte LABEL_ORDER_FINISHED = 9;//订单商家确认完成
    public static final byte LABEL_ORDER_SALING = 5;//售后中
    public static final byte LABEL_ORDER_GIVEUP = -1;//主动放弃兑换
    public static final byte LABEL_ORDER_LOSS_FOR_INIT_TIMEOUT = -2;//由于超时失去兑换资格
    public static final byte LABEL_ORDER_CLOSED = 6;//已关闭


    public static Map<Byte, String> labelStatusMap = new HashMap<>();

    static {
        labelStatusMap.put(ConstantsRef.LABEL_ORDER_INIT, "待核对");
        labelStatusMap.put(ConstantsRef.LABEL_ORDER_WAIT_MERCHANT_CONFIRM, "待确认");
        labelStatusMap.put(ConstantsRef.LABEL_ORDER_FINISHED, "已完成");
        labelStatusMap.put(ConstantsRef.LABEL_ORDER_SALING, "售后中");
        labelStatusMap.put(ConstantsRef.LABEL_ORDER_CLOSED, "已关闭");
        labelStatusMap.put(ConstantsRef.LABEL_ORDER_GIVEUP, "已放弃");
        labelStatusMap.put(ConstantsRef.LABEL_ORDER_LOSS_FOR_INIT_TIMEOUT, "已放弃");

    }

    public static Map<Byte, String> labelStatusToolTipMap = new HashMap<>();

    static {
        labelStatusToolTipMap.put(ConstantsRef.LABEL_ORDER_INIT, "买家正在核对商品信息");
        labelStatusToolTipMap.put(ConstantsRef.LABEL_ORDER_WAIT_MERCHANT_CONFIRM, "买家已核对商品信息，请确认");
        labelStatusToolTipMap.put(ConstantsRef.LABEL_ORDER_SALING, "小二正在处理中...");
        labelStatusToolTipMap.put(ConstantsRef.LABEL_ORDER_FINISHED, "活动已完成");
        labelStatusToolTipMap.put(ConstantsRef.LABEL_ORDER_GIVEUP, "活动已被放弃");
        labelStatusToolTipMap.put(ConstantsRef.LABEL_ORDER_LOSS_FOR_INIT_TIMEOUT, "活动已被放弃");
        labelStatusToolTipMap.put(ConstantsRef.LABEL_ORDER_CLOSED, "小二已对活动进行判定，关闭订单");
    }


    //答题题目类型
    public static final byte EXCHANGE_QA_MAX_CHECK_TIMES = 5;//答题时可核对的最大次数
    public static final byte EXCHANGE_QA_TYPE_OF_INPUT = 1;//问答题
    public static final byte EXCHANGE_QA_TYPE_OF_SELECT = 2;//选择题
    public static final byte EXCHANGE_QA_ANSWERED_RIGHT = 1;//已答过且答对
    public static final byte EXCHANGE_QA_ANSWERED_NOT = 0;//未答题或答题错误

    //放弃兑换阶段
    public static final byte GIVEUP_PHASE_OF_ORDER_INIT = 0;//订单答题阶段放弃
    public static final byte GIVEUP_PHASE_OF_ORDER_WAIT_SUBMIT = 1;//订单待提交阶段放弃

    //黑钻操作类型
    public static final byte BLACKDIAMOND_SUBSTRACT_FOR_EXCHANGE = 1;//兑换消耗黑钻
    public static final byte BLACKDIAMOND_ADD_FOR_QA = 2;//答题奖励黑钻
    public static final byte BLACKDIAMOND_ADD_FOR_SUPPLEMENT_INFO = 3;//完善资料奖励黑钻
    public static final byte BLACKDIAMOND_ADD_FOR_SUPPLEMENT_LABEL = 13;//完善个性标签
    public static final byte BLACKDIAMOND_ADD_FOR_GIVEUP_EXCHANGE = 4;//放弃兑换，返还消耗黑钻
    public static final byte BLACKDIAMOND_ADD_FOR_INVITE = 5;//买家邀请获取黑钻
    public static final byte BLACKDIAMOND_ADD_FOR_INVITE_LEVEL = 6;//买家达到等级获取黑钻
    public static final byte BLACKDIAMOND_ADD_FOR_BIND_TAOBAO = 7;//用户绑定淘宝信息
    public static final byte BLACKDIAMOND_SUBSTRACT_FOR_ORDER_CLOSED = 8;//订单关闭
    public static final byte BLACKDIAMOND_SUBSTRACT_FOR_ORDER_FINISH = 9;//订单完成
    public static final byte BLACKDIAMOND_ADD_FOR_ACTIVITY_REWARD = 30;//活动奖励
    public static final byte BLACKDIAMOND_SUBSTRACT_FOR_EXAMINE = 40;//系统校验，核查黑钻非正常来源，并扣除
    public static final byte BLACKDIAMOND_SUBSTRACT_FOR_INVALID_INVITE = 41;//无效邀请扣除黑钻
    public static final byte BLACKDIAMOND_ADD_FOR_SYS_REWARD = 42;//系统（小二）奖励
    public static final byte BLACKDIAMOND_ADD_FOR_LABEL = 100;//活动打标

    public static final byte BLACKDIAMOND_ADD_FOR_QI = 10;//问卷调查奖励黑钻
    public static final byte BLACKDIAMOND_ADD_FOR_SCORE = 11;//订单商品评分奖励黑钻

    public static final byte BLACKDIAMOND_ADD_FOR_RECHARGE = 20;//黑钻充值
    public static final byte BLACKDIAMOND_ADD_FOR_FIRST_RECHARGE_GIVEN = 21;//黑钻首充赠送
    public static final byte BLACKDIAMOND_ADD_FOR_RECHARGE_GIVEN = 22;//黑钻充值赠送
    public static final byte BLACKDIAMOND_ADD_FOR_STAR_EVALUATION = 23;//撰写测评报告
    public static final byte BLACKDIAMOND_ADD_FOR_TAOBAO_EVALUATION = 24;//邀请测评
    public static final byte BLACKDIAMOND_ADD_FOR_TAOBAO_EVALUATION_REWARD = 26;//测评奖励
    public static final byte BLACKDIAMOND_ADD_FOR_PUBLISH_EVALUATE = 23;//发表测评

    public static final byte BLACKDIAMOND_ADD_FOR_FINISH_EVALUATE = 24;//淘宝测评已确认完成


    public static final byte BLACKDIAMOND_ADD_FOR_PLAY_VIDEO = 25;//参与星球玩法，播放玩法视频奖励

    //兑换需要的黑钻数
    //public static final int BLACKDIAMOND_NUM_FOR_EXCHANGE = 10;//兑换默认需要10黑钻
    //public static final int BLACKDIAMOND_EXCHANGE_RATE = 10;//商品价格价格(人民币)与黑钻的兑换比例

    //黑钻充值首充赠送黑钻数
    public static final BigDecimal BLACKDIAMOND_NUM_FOR_RECHARGE_GIVEN = new BigDecimal("0");//首充奖励0黑钻
    //黑钻充值首充赠送充值数量比例
    public static final BigDecimal BLACKDIAMOND_NUM_FOR_RECHARGE_GIVEN_RATE = new BigDecimal("0.1");

    //答题奖励的黑钻数
    public static final int BLACKDIAMOND_NUM_FOR_QA = 10;//默认奖励10黑钻

    //问卷调查淘口令方式奖励的黑钻数
    public static final int BLACKDIAMOND_NUM_FOR_QI_STR = 5;

    //问卷调查截图方式奖励的黑钻数
    public static final int BLACKDIAMOND_NUM_FOR_QI_URL = 10;

    public static final int BLACKDIAMOND_NUM_FOR_LABEL_QA = 5;//默认奖励10黑钻
    //绑定淘宝账号（会员名）奖励黑钻数
    public static final int BLACKDIAMOND_NUM_FOR_BIND_TAOBAO = 1100;//默认奖励1000黑钻
    //订单商品评分奖励黑钻
    public static final int BLACKDIAMOND_NUM_FOR_SCORE = 20;//奖励20黑钻

    //库存累加：针对上一活动时间段结束，但商品数量未兑换完，为了增加活动任务的完成率，将剩余的商品数量累加到下一活动时间段
    public static final byte ACCUMULATED_NO = 0;//0：正常，未累加到下一活动时间段
    public static final byte ACCUMULATED_YES = 1;//1：活动时间段已结束，但有剩余商品，数量已累加到下一活动时间段


    //买家资金流水的账户类型（账户类型；1：可提现金额  2：提现中金额  3：交易中（待返现）金额   金额单位：金币）
    //10:可提现的代理佣金   20：提现中的代理佣金

    public static class ExpertFundSerialFundType {
        public static final byte ENABLE_WITHDRAW = 1;
        public static final byte WITHDRAWING = 2;
        public static final byte WAIT_RETURN = 3;

        public static final byte ENABLE_WITHDRAW_AGENT_COMMISSION = 10;
        public static final byte WITHDRAWING_AGENT_COMMISSION = 20;

    }

    /**
     * 买家资金流水操作类型：
     * 1：交易中已确认签收，待返现（返至金币钱包），待返现即“交易中”数额增加；
     * 2：已返现（返至金币钱包，账户“可提现”数额增加 ，“交易中”数额减少）；
     * 3：提现申请中（“提现中数额”增加，“可提现数额”减少）；
     * 4：提现成功 （“可提现”数额减少，“提现中”数额减少）；
     * 5：提现被拒绝（“提现中”数额减少，“可提现”数额增加）；
     * 6：交易中已确认签收，但发起售后走了“订单关闭”流程，则用户“交易中”数额需要扣除；
     * 7：手动模式订单售后修改金额，引起的“交易中”金额修改；
     * 50:提现代理佣金
     * 100：活动打标
     * 101：被邀请人完成付款活动，代理获得佣金
     */
    public static class ExpertFundSerialOperType {
        public static final byte RECEIVED_AND_WAIT_RETURN = 1;
        public static final byte RETURNED_GOLD_POCKET = 2;
        public static final byte WITHDRAW_INITIATE = 3;
        public static final byte WITHDRAW_SUCCESS = 4;
        public static final byte WITHDRAW_REJECTED = 5;
        public static final byte RECEIVED_AND_CLOSE_ORDER_NOT_RETURN = 6;
        public static final byte SALING_MAUNAL_ORDER_PAYAMOUNT_MODIFY = 7;


        public static final byte AGENT_GET_EXCHANGE_COMMISSION = 101;
        public static final byte BE_INVITED_USER_CLOSE_ORDER = 102;

    }

    /**
     * 用户黑钻流水资金类型：
     * 1.可用黑钻  2.交易中黑钻
     */
    public static class ExpertBlackdiamondSerialFundType {
        public static final byte ENABLE_BLACKDIAMOND = 1;
        public static final byte TRADING_BLACKDIAMOND = 2;

    }

    /**
     * 商家资金流水的账户类型（账户类型；1：可用金币；2：可用服务费；3：保证金； 11：冻结金币  ；21冻结服务费）
     */
    public static class MerchantFundSerialType {
        public static final byte ENABLE_USE_GOLD = 1;
        public static final byte ENABLE_USE_DIAMOUND = 2;
        public static final byte DEPOSIT = 3;
        public static final byte FROZEN_GOLD = 11;
        public static final byte FROZEN_DIAMOUND = 21;


        public static final byte ENABLE_USE_SERVICE_FEE = 4;
    }


    /**
     * 资金流水oper_type ADD:
     * 商家资金流水操作类型
     * 100：当天结算；
     * 101：活动组当前已终止，用户放弃兑换（返商家账户可用增加，冻结减少）；
     * 102：活动组当前已结算，用户放弃兑换（返商家账户可用增加，冻结减少）；
     * 50.活动已完成-用户担保金返现 ，商家冻结金币减少
     * 51.活动已完成-用户担保金返现 ，商家冻结服务费减少
     * 52.活动已完成-补差额给到商家可用资金（实际支付价格小于活动价的情况）
     */
    public static final class MerchantFundSerialOperType {
        public static final byte TYPE_RECHARGE_COIN_ADD = 1;//金币充值
        public static final byte TYPE_RECHARGE_DIAMOND_ADD = 2;//服务费充值
        public static final byte TYPE_RECHARGE_ASSURE_ADD = 16;//保证金充值
        public static final byte TYPE_RECHARGE_COIN_SUB = 17;//消耗金币，充值保证金

        public static final byte TYPE_ACTIVITY_COIN_FROZEN = 3;//发布活动-预缴金币保证金，资金冻结
        public static final byte TYPE_ACTIVITY_COIN_UNFROZEN = 4;//活动结束-金币保证金解冻（返还多少看实际使用）
        public static final byte TYPE_ACTIV_DIAMOND_FROZEN = 5;//发布活动-预缴服务费
        public static final byte TYPE_ACTIV_DIAMOND_UNFROZEN = 6;//活动结束-服务费解冻（返还多少看实际使用）

        public static final byte TYPE_ASSESS_COIN_SUB = 7;//买家测评活动，金币扣除
        public static final byte TYPE_ASSESS_DIAMOND_SUB = 8;//买家测评活动，服务费扣除

        public static final byte TYPE_OPE_ACCOUNT_9 = 9;//

        public static final byte TYPE_SHOP_COIN_SUB_1 = 10;//绑定店铺
        public static final byte TYPE_SHOP_COIN_SUB_2 = 11;//换绑店铺
        public static final byte TYPE_SMS_COIN_SUB = 12;//短信消费
        public static final byte TYPE_VIDEO_COIN_SUB = 13;//开通视频
        public static final byte TYPE_MEMBER_COIN_SUB = 14;//开通付费会员

        public static final byte TYPE_WITHD_COIN_SUB = 15;//金币提现（走线下，且需平台方审核，服务费不能提现）

        public static final byte TYPE_MERCHANT_QUIT_COIN = 31;//商家金币退费
        public static final byte TYPE_MERCHANT_QUIT_DIAMOND = 32;//商家服务费退费

        public static final byte MERCHANT_SETTLED = 100;
        public static final byte STOPPED_AND_GIVEUP_EXCHANGE = 101;//已终止后，放弃兑换
        public static final byte SETTLED_AND_GIVEUP_EXCHANGE = 102;//已结算后，放弃兑换
        public static final byte TIMEOUT_ORDER_INIT = 103;//订单兑换超时
        public static final byte TIMEOUT_ORDER_SUBMIT = 104;//订单提交超时
        public static final byte SALING_CLOSE_ORDER = 105;//售后处理->关闭订单


        public static final byte ORDER_FINISHED_FROZEN_COIN_REDUCE = 50;
        public static final byte ORDER_FINISHED_FROZEN_DIAMOND_REDUCE = 51;
        public static final byte ORDER_FINISHED_RETURN_DIFF_AMOUNT = 52;
        public static final byte ORDER_FINISHED_RETURN_DIFF_FEE = 53;//活动已完成-补差额给到商家可用服务费（实际订单服务费小于活动服务费的情况）


        public static final byte LABLE_ORDER_FINISHED = 60;//打标活动商家确认完成

        public static final byte INVITE_USER_TAOBAO_EVALUATE = 70;//邀请买家去淘宝测评，需冻结5服务费

        public static final byte GIVEUP_TAOBAO_EVALUATE = 71;//买家淘宝测评超时，返商家冻结的5服务费

        public static final byte SETTLE_EVALUATE_ORDER = 72;//结算商家测评订单，冻结扣除5服务费


        public static final byte RETURN_MONEY = 99;//返款操作


        public static final byte REDPACKET_ADD_TASK = 100;//发布普通（返款）红包任务
        public static final byte REDPACKET_STOP_TASK = 101;//停止普通（返款）红包任务
        public static final byte REDPACKET_BUYER_RECEIVED = 102;//买家领取普通（返款）红包


        public static final byte REDPACKET_FIXED_ADD_TASK = 110;//发布营销红包任务
        public static final byte REDPACKET_FIXED_STOP_TASK = 111;//停止营销红包任务
        public static final byte REDPACKET_FIXED_BUYER_RECEIVED = 112;//买家领取营销红包


    }

    public static final class MerchantPointSerialOperType {
        public static final byte CHECK_TAOKE = 1;//检查是否淘客订单
    }

    /***************** 店铺管理 *********************/
    public static final int ADD_SHOP_FREE_COUNT = 2;//会员免费绑定店铺的个数

    public static final int BIND_SHOP_LIMIT_COUNT = 1000;//绑定店铺数量上限

    public static final String BLACKDIAMOND_RECHARGE_DAYOFWEEK = "1,2,3,4,5,6,7";//数值代表周几，如2为周二，7为周日，多个以逗号分隔

    /***************** 提现 *********************/

    //============ 提现限制
    public static final int WITHDRAWAL_MONTH_MAX_TIMES = 30;//用户当月可免费提现次数
    public static final int WITHDRAWAL_DAY_MAX_TIMES = 1;//用户每天可免费提现次数
    public static final BigDecimal WITHDRAWAL_EACH_FIX_CHARGE = new BigDecimal(2.00);   //用户每笔固定提现收取费用
    //public static final BigDecimal WITHDRAWAL_BILL99_ADVANCE_MONEY = new BigDecimal(1.00);   //快钱付款（提现），因为需要从付款金额中扣除费用，平台需要垫付费用 == 快钱处理费用
    //【new-start】无需快钱支付，直接走线下转账的方式，所有就无需支付"快钱处理费用"
    public static final BigDecimal WITHDRAWAL_BILL99_ADVANCE_MONEY = new BigDecimal(0.00);
    public static final BigDecimal WITHDRAWAL_LEAST_MONEY = new BigDecimal(10.00);      //最低提现金额


    public static final int WITHDRAWAL_COMMISSION_MONTH_MAX_TIMES = 30;//用户佣金当月可免费提现次数
    public static final BigDecimal WITHDRAWAL_LEAST_COMMISSION = new BigDecimal(100.00);//佣金最低提现金额


    //============ 提现账户
    public static final byte WITHDRAWAL_APPLY_WHITHER_BANK = 1;         //提现去处-银行
    public static final byte WITHDRAWAL_APPLY_WHITHER_WECHAT = 2;       //提现去处-微信
    public static final byte WITHDRAWAL_APPLY_FUND_TYPE_COIN = 1;       //提现账户类型-金币

    //============ 提现状态
    public static final int WITHDRAWAL_APPLY_AUDIT_WAIT = 10;           //提现审核状态-待审核
    public static final int WITHDRAWAL_APPLY_AUDIT_REFUSE = 14;           //提现审核状态-审核拒绝
    public static final int WITHDRAWAL_APPLY_AUDIT_PASS = 16;           //提现审核状态-审核通过
    public static final int WITHDRAWAL_APPLY_FAIL = 18;           //提现审核状态-提现失败
    public static final int WITHDRAWAL_APPLY_SUCCESS = 20;           //提现审核状态-提现成功
    public static final int WITHDRAWAL_APPLY_ERR = 99;//错误的申请记录
    //public static final int WITHDRAWAL_APPLY_AUDIT_REMITTING = 30;      //提现审核状态-打款中--废弃
    //public static final int WITHDRAWAL_APPLY_TRANSACTION_COMPLETE = 90;    //提现交易完成（绝对完成）--废弃


    /***************** 黑钻奖励 *********************/

    public static final BigDecimal BLACKDIAMOND_EXCHANGE_RATIO = new BigDecimal(0.10);      //黑钻兑换比例，1黑钻的价值

    public static final class BlackdiamondAward {

        public static final BigDecimal LABEL_AWARD = new BigDecimal(10.00); //打标奖励

        public static final BigDecimal INVITE_EXPERT = new BigDecimal(500.00);              //邀请买家
        public static final BigDecimal INFORMATION_ADD_GENDER = new BigDecimal(100.00);              //性别
        public static final BigDecimal INFORMATION_ADD_BIRTHDATE = new BigDecimal(100.00);           //出生日期
        public static final BigDecimal INFORMATION_ADD_MOBILE = new BigDecimal(200.00);            //手机
        public static final BigDecimal INFORMATION_ADD_RECEIVING_ADDRESS = new BigDecimal(100.00);  //收货地址
        public static final BigDecimal INFORMATION_ADD_TAOBAO_ACCOUNT = new BigDecimal(100.00);       //淘宝会员名
        public static final BigDecimal INFORMATION_ADD_TAOBAO_TAOQIZHI = new BigDecimal(100.00);    //淘气值
        public static final BigDecimal INFORMATION_ADD_HEIGHT = new BigDecimal(50.00);              //身高
        public static final BigDecimal INFORMATION_ADD_WEIGHT = new BigDecimal(50.00);              //体重
        public static final BigDecimal INFORMATION_ADD_AUTHENTICATION = new BigDecimal(100);       //实名认证
        public static final BigDecimal INFORMATION_ADD_BANK_CARD = new BigDecimal(1000);            //绑定银行卡
        public static final BigDecimal INFORMATION_ADD_WECHAT = new BigDecimal(50.00);             //绑定微信
        public static final BigDecimal INFORMATION_ADD_QQ = new BigDecimal(50.00);                 //绑定QQ

        //标签资料奖励
        public static final BigDecimal INFORMATION_LABEL_PROFESSION = new BigDecimal("10.00");//职业
        public static final BigDecimal INFORMATION_LABEL_MOBILE_BRAND = new BigDecimal("10.00");//手机品牌
        public static final BigDecimal INFORMATION_LABEL_EDUCATION = new BigDecimal("10.00");//教育程度
        public static final BigDecimal INFORMATION_LABEL_LIFE_STAGE = new BigDecimal("10.00");//人生阶段
        public static final BigDecimal INFORMATION_LABEL_FAMILY_MERBER = new BigDecimal("10.00");//家庭成员
        public static final BigDecimal INFORMATION_LABEL_ASSET = new BigDecimal("10.00");//资产信息
        public static final BigDecimal INFORMATION_LABEL_MONTHLY_INCOME = new BigDecimal("10.00");//月均收入
        public static final BigDecimal INFORMATION_LABEL_MONTHLY_CONSUME = new BigDecimal("10.00");//月均消费
        public static final BigDecimal INFORMATION_LABEL_SHOPPING_PLATFORM = new BigDecimal("10.00");//购物平台
        public static final BigDecimal INFORMATION_LABEL_HOBBIES = new BigDecimal("10.00");//兴趣爱好


        //测评奖励黑钻
        public static final BigDecimal PUBLISH_EVALUATE = new BigDecimal("20.00");
        //测评奖励黑钻-旧
        public static final BigDecimal PUBLISH_EVALUATE_OLD = new BigDecimal("30.00");
        //优质测评奖励黑钻300旧
        public static final BigDecimal PUBLISH_HIGH_QUALITY_EVALUATE_OLD_SECOND = new BigDecimal("300.00");
        //优质测评奖励黑钻100
        public static final BigDecimal PUBLISH_HIGH_QUALITY_EVALUATE = new BigDecimal("100.00");
        //商家邀请测评，买家提交后且商家确认后奖励50
        public static final BigDecimal PUBLISH_INVITATION_EVALUATE_OLD_SECOND = new BigDecimal("50.00");
        //商家邀请测评，买家提交后且商家确认后奖励300
        public static final BigDecimal PUBLISH_INVITATION_EVALUATE = new BigDecimal("300.00");

        //观看玩法视频
        public static final BigDecimal PLAY_VIDEO = new BigDecimal("10.00");
    }

    //重连次数
    public static final int CONNECT_TRY_TIMES = 3;

    //项目部署域名
    public static final String DEPLOY_DOMAIN_NAME = "http://lpapi.sousuotemai.com/";


    public static final class AftersaleStatus {
        public static final byte APPLY = 0;//申请售后
        public static final byte ACCEPTED = 1;//售后受理中
        public static final byte CANCEL_APPLY = -1;//取消申请售后
        public static final byte FINISHED = 9;//售后处理完成
        public static final byte USER_TYPE_OF_MERCHANT = 1;//B端商家
        public static final byte USER_TYPE_OF_OPERATION = 2;//运营人员
        public static final byte USER_TYPE_OF_EXPERT = 3;//C端买家

    }

    /**
     * 邀请买家淘宝测评状态
     */
    public static final class InviteTaobaoStatus {
        public static final byte NO_INVITE = 0;//未邀请
        public static final byte INVITED = 1;//已邀请
        public static final byte SUBMIT_EVALUATED = 2;//收到邀请已在淘宝评价
        public static final byte FINISHED = 9;//测评已完成
        public static final byte TIMEOUT_NO_EVALUATE = -1;//收到邀请未在淘宝评价==超时未评价（收到商家邀请后7天内提交凭证，超时算放弃）
        public static final byte AFTER_SALE = 5;//售后
    }

    /**
     * 短信模板code
     */
    public static final class SmsTemplateCode {

        public static final String MERCHANT_AUTHENTICATION = "SMS_169865350";//商家身份验证
        public static final String MERCHANT_RECHARGE_AUDIT = "SMS_173473485";//充值待审核(适用于红包充值、b2b【小B到到大B】,b2p【代理到平台】)
        public static final String MERCHANT_RECHARGE_AUDIT_PASS = "SMS_173473493";//充值审核通过


    }

    public static Map<String, String> SmsTemplateMap = new HashMap<>();

    static {

        SmsTemplateMap.put(SmsTemplateCode.MERCHANT_AUTHENTICATION, "粉盟粉丝互换助手");
        SmsTemplateMap.put(SmsTemplateCode.MERCHANT_RECHARGE_AUDIT, "粉盟粉丝互换助手");
        SmsTemplateMap.put(SmsTemplateCode.MERCHANT_RECHARGE_AUDIT_PASS, "粉盟粉丝互换助手");
    }


    //订单提交模式:1:自动提交  2:手动提交
    public static final byte SUBMIT_MODE_OF_AUTO = 1;
    public static final byte SUBMIT_MODE_OF_MANUAL = 2;

    //权重操作类型
    public static final class WeightOperType {
        public static final int BUY_BACK = 10;
        public static final int JOIN_LABEL = 20;
    }

    //打标活动获取权重基础分值
    public static final int WEIGHT_FOR_LABEL_ACTIVITY_BASICS = 10;


    //消息或视频每次点击、点赞
    public static final int ADD_FAKE_TIMES_FOR_CLICK = 9;
    //权重最低分值
    public static final int WEIGHT_LOWEST_VALUE = 0;

    //权重最高分值
    public static final int WEIGHT_HIGHEST_VALUE = 100;

    //最大年龄
    public static final int AGE_LOWEST_VALUE = 12;
    //最小年龄
    public static final int AGE_HIGHEST_VALUE = 60;
    //超过年龄限制提示
    public static final String AGE_LIMIT_HINT = "超过规定年龄区间，请重新选择";


    // 1(红色), 2(黄色), 3(绿色), 4(蓝色), 5(粉红色)
    public static final Map<String, Byte> flagMap = new HashMap<>();

    static {
        flagMap.put("red", (byte) 1);
        flagMap.put("yellow", (byte) 2);
        flagMap.put("green", (byte) 3);
        flagMap.put("blue", (byte) 4);
        flagMap.put("pink", (byte) 5);
    }


    //旺旺权重分每天最大查询次数
    public static final int MAX_WANGWANG_WEIGHT_SEARCH_DAY_TIMES = 100;

    //旺旺实时标签每天最大查询次数
    public static final int MAX_WANGWANG_TAGS_SEARCH_DAY_TIMES = 100;


}
